<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<META HTTP-EQUIV="CACHE-CONTROL" CONTENT="NO-CACHE">
<link rel="stylesheet" type="text/css" href="main.css" />
<title>Insert title here</title>
<script type="text/javascript" src="/ils/jquery.js"></script>
<script type="text/javascript">
	count = 1;
$(document).ready(function(){
	
	$("button#button1").click(function(){
		var html = " <br /><br />Book Name: <input type='text' name='items[" + count + "].bookName' /><br />" +
		"ISBN: <input type='text' name='items[" + count + "].isbn' /><br />" +
		"ISSN: <input type='text' name='items[" + count + "].issn' /><br />" +
		"Quantity: <input type='text' name='items[" + count + "].quantity' /><br />";
		$("p#marker1").before(html);
		count++;
	});
});
function closeWindow()
{
	window.close();	
}
</script>
</head>
<body>
	<form action="placeOrder">
		SellerId: <input type="text" name="sellerId" /><br />
		Book Name: <input type="text" name="items[0].bookName" /><br />
		ISBN: <input type="text" name="items[0].isbn" /><br />
		ISSN: <input type="text" name="items[0].issn" /><br />
		Quantity: <input type="text" name="items[0].quantity" /><br />
		<p id="marker1" />
		<input type="submit" name="submit" /> 
	</form>
	<button id="button1">Add More Books</button>
	<button onclick="closeWindow()">Cancel</button>
</body>
</html>